1. Field of the Invention
This invention relates to computer network technology, and more particularly, to a relay control method and circuit with an improved load-balancing capability based on user-predefined port group configuration, which is designed for use on a computer network system, such as Ethernet, to allow an increased network data communication efficiency.
2. Description of Related Art
Although Ethernet is the most popular local area network, a transmission rate of 10Mbps (bit per second) is not enough for multimedia communication. Consequently, an improved solution, Fast Ethernet, which has a transmission rate of 100 Mbps, is developed. However, in fast Ethernet an additional convergence sublayer (CS) must be introduced between the media access control (MAC) sublayer and the physical medium dependent (PMD) sublayer. Hence, the network interface card must be updated by a fast Ethernet interface card. However, in the case of increasing the transmission rate without updating the original slow network interface card in each network station, an Ethernet switch structure is preferred.
In the conventional Ethernet, a twisted wires is used as a medium for network connection. It does not matter if the transmission rate is 10 Mbps or 100 Mbps, workstations and server are linked together through an Ethernet hub so that network data are shared. In general, bandwidth of the hub is shared by the linked workstations attached to the network. For example, for a 100 Mbps Ethernet hub with 16 ports, if 4 ports are connected to workstations, network bandwidth is shared by the 4 workstations. If 16 ports are connected to workstations, network bandwidth is shared by the 16 workstations. As the number of network users increases, network collision will become more serious and bandwidth assigned to each user will be narrower as well. Hence, conventional Ethernet hub is no longer capable of satisfying the demands of users.
An Ethernet switch is developed for improving network bandwidth. The Ethernet switch permits the simultaneous data transmission of several connected workstations so that overall performance of the network is increased. To achieve the switching function, the Ethernet switch must know which port a workstation is connected to. In other words, the Ethernet switch must have an address learning function similar to a bridge device. When the switch receives a frame signal, a routing table will be consulted to lookup for the port connected to the destination workstation. If the port is found, a control processor will send out a control signal to a switching element so that the frame signal is output to the port. Conversely, if the port is not found in the routing table, the frame signal will be broadcast to every connected port so that the destination workstation is sure to receive the frame.
Assume that N is the number of connection ports in an Ethernet switch, the switch is capable of transmitting frame signal to a maximum of N/2 workstations. For example, a 16 ports 100 Mbps Ethernet switch can have a maximum network bandwidth of 800 Mbps if collisions are ignored. On the other hand, a 16 ports 100 Mbps Ethernet hub can have a maximum network bandwidth of just 100 Mbps. Hence, there is a tremendous improvement in transmission capability for the Ethernet.
As the Ethernet is increased in the number of users, traffic jam becomes a serious problem, particularly at the server. To solve this problem, the Ethernet Switch is designed to provide a load-balancing capability based on user-predefined port group configuration. With this capability, the user or network manager can predefine a port group configuration that can provide an optimal load-balancing operation to the data communication loading on the Ethernet Switch. For instance, assume the Ethernet Switch has 8 ports, the user can predefine Port 1, Port 2, Port 3, and Port 4 in the same group to allow these four ports to share data communication loading on the Ethernet Switch. In other words, if one of the four ports in this group, for example Port 1, has an enormous amount of data communication loading while the other three ports, i.e., Port 2, Port 3, and Port 4, are relatively less loaded, then the Ethernet Switch device will dispatch some of the received data frames, which are originally intended to be transmitted via Port 1, via the other three ports to their destinations. This increases the overall network data communication efficiency through the Ethernet Switch.
One solution of insufficient bandwidth is to combine a number of ports on the Ethernet Switch into a trunk (group) and allow the overall data communication loading in the same trunk to be equally allocated. Presently, the allocation method includes a dynamic allocation method and a static allocation method. The dynamic allocation method allocates data communication loading to each port based on the current loading so that the dynamic allocation method can be performed more data-balancing among the ports. One drawback of the dynamic allocation method, however, is that it can easily cause disordered sequences of frames forwarding. By contrast, the static allocation method allocates data communication loading to all of the ports irrespective of the current loading of each port, and therefore can preserve the sequences of frames forwarding. But the static allocation method would be performed less data balancing among the ports. In the event that the sequences of data frames are disordered, it requires much time and efforts to recover the original ordered sequencing. For this reason, the static allocation method is more preferable than the dynamic allocation method.
On an Ethernet Switch that utilizes the static allocation method, since parity check is performed on the binary address information indicative of the destination, the number of ports in each group should be a 2's power, i.e., 2N, where N is the number of bits used in the parity check. Therefore, in the case of 1-bit parity check, each group contains 2 ports (21=2); in the case of 2-bit parity check, each group contains 4 ports (22=4); and in the case of 3-bit parity check, each group contains 8 ports (23=8). For 8-port Ethernet Switch, the 8 ports can be configured depending on the number of parity-check bits, either into 4 groups with each group containing 2 ports; or into 2 groups with each group containing 4 ports; or into a single group containing all the 8 ports. Beside these, other configurations schemes are not allowed. In the case that an Ethernet server is installed with 3 Ethernet cards, and load-balancing capability is desired, the Ethernet Switch device should be configured in such a manner as to allow the group to contain 4 ports. Assume Port 1, Port 2, Port 3, and Port 4 are assigned to the same group, and the 3 Ethernet cards in the server are respectively connected to Port 1, Port 2, and Port 3. In this case, when the load-balancing operation is directed to Port 4, the current data will be unable to be sent out via Port 4 immediately. Instead, the current data will wait until a timeout period is passed, and then can be sent out via another port. This would undoubtedly degrade the overall network data communication efficiency.